home *** CD-ROM | disk | FTP | other *** search
Wrap
/* * DO NOT EDIT. THIS FILE IS GENERATED FROM nsIXPInstallManager.idl */ #ifndef __gen_nsIXPInstallManager_h__ #define __gen_nsIXPInstallManager_h__ #ifndef __gen_nsISupports_h__ #include "nsISupports.h" #endif /* For IDL files that don't want to include root IDL files. */ #ifndef NS_NO_VTABLE #define NS_NO_VTABLE #endif class nsIXPIProgressDialog; /* forward declaration */ /* starting interface: nsIXPInstallManager */ #define NS_IXPINSTALLMANAGER_IID_STR "566689cb-9926-4bec-a66e-a034e364ad2c" #define NS_IXPINSTALLMANAGER_IID \ {0x566689cb, 0x9926, 0x4bec, \ { 0xa6, 0x6e, 0xa0, 0x34, 0xe3, 0x64, 0xad, 0x2c }} /** * Interface to XPInstallManager - manages download and install operations. */ class NS_NO_VTABLE nsIXPInstallManager : public nsISupports { public: NS_DEFINE_STATIC_IID_ACCESSOR(NS_IXPINSTALLMANAGER_IID) /** * Initiates a download and install operation of the supplied URLs * and sends notifications to the supplied listener. * @param aURLs array of XPI urls to download and install * @param aURLCount number of XPI urls in aURLs * @param aListener a listener to receive status notifications */ /* void initManagerFromChrome ([array, size_is (aURLCount)] in wstring aURLs, in unsigned long aURLCount, in nsIXPIProgressDialog aListener); */ NS_IMETHOD InitManagerFromChrome(const PRUnichar **aURLs, PRUint32 aURLCount, nsIXPIProgressDialog *aListener) = 0; /** * Initiates a set of downloads and checks the supplied hashes after * download. Just like initManagerFromChrome() in all other respects * @param aURLs array of XPI urls to download and install * @param aHashes array of hash strings to validate. The entire array * or individual hashes can be null to indicate no * checking. If supplied looks like "type:hash", like * "md5:3232bc5624041c507db0965324188024". * Supports the types in nsICryptoHash * @param aURLCount number of XPI urls in aURLs and aHashes * @param aListener a listener to receive status notifications */ /* void initManagerWithHashes ([array, size_is (aURLCount)] in wstring aURLs, [array, size_is (aURLCount)] in string aHashes, in unsigned long aURLCount, in nsIXPIProgressDialog aListener); */ NS_IMETHOD InitManagerWithHashes(const PRUnichar **aURLs, const char **aHashes, PRUint32 aURLCount, nsIXPIProgressDialog *aListener) = 0; }; /* Use this macro when declaring classes that implement this interface. */ #define NS_DECL_NSIXPINSTALLMANAGER \ NS_IMETHOD InitManagerFromChrome(const PRUnichar **aURLs, PRUint32 aURLCount, nsIXPIProgressDialog *aListener); \ NS_IMETHOD InitManagerWithHashes(const PRUnichar **aURLs, const char **aHashes, PRUint32 aURLCount, nsIXPIProgressDialog *aListener); /* Use this macro to declare functions that forward the behavior of this interface to another object. */ #define NS_FORWARD_NSIXPINSTALLMANAGER(_to) \ NS_IMETHOD InitManagerFromChrome(const PRUnichar **aURLs, PRUint32 aURLCount, nsIXPIProgressDialog *aListener) { return _to InitManagerFromChrome(aURLs, aURLCount, aListener); } \ NS_IMETHOD InitManagerWithHashes(const PRUnichar **aURLs, const char **aHashes, PRUint32 aURLCount, nsIXPIProgressDialog *aListener) { return _to InitManagerWithHashes(aURLs, aHashes, aURLCount, aListener); } /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */ #define NS_FORWARD_SAFE_NSIXPINSTALLMANAGER(_to) \ NS_IMETHOD InitManagerFromChrome(const PRUnichar **aURLs, PRUint32 aURLCount, nsIXPIProgressDialog *aListener) { return !_to ? NS_ERROR_NULL_POINTER : _to->InitManagerFromChrome(aURLs, aURLCount, aListener); } \ NS_IMETHOD InitManagerWithHashes(const PRUnichar **aURLs, const char **aHashes, PRUint32 aURLCount, nsIXPIProgressDialog *aListener) { return !_to ? NS_ERROR_NULL_POINTER : _to->InitManagerWithHashes(aURLs, aHashes, aURLCount, aListener); } #if 0 /* Use the code below as a template for the implementation class for this interface. */ /* Header file */ class nsXPInstallManager : public nsIXPInstallManager { public: NS_DECL_ISUPPORTS NS_DECL_NSIXPINSTALLMANAGER nsXPInstallManager(); private: ~nsXPInstallManager(); protected: /* additional members */ }; /* Implementation file */ NS_IMPL_ISUPPORTS1(nsXPInstallManager, nsIXPInstallManager) nsXPInstallManager::nsXPInstallManager() { /* member initializers and constructor code */ } nsXPInstallManager::~nsXPInstallManager() { /* destructor code */ } /* void initManagerFromChrome ([array, size_is (aURLCount)] in wstring aURLs, in unsigned long aURLCount, in nsIXPIProgressDialog aListener); */ NS_IMETHODIMP nsXPInstallManager::InitManagerFromChrome(const PRUnichar **aURLs, PRUint32 aURLCount, nsIXPIProgressDialog *aListener) { return NS_ERROR_NOT_IMPLEMENTED; } /* void initManagerWithHashes ([array, size_is (aURLCount)] in wstring aURLs, [array, size_is (aURLCount)] in string aHashes, in unsigned long aURLCount, in nsIXPIProgressDialog aListener); */ NS_IMETHODIMP nsXPInstallManager::InitManagerWithHashes(const PRUnichar **aURLs, const char **aHashes, PRUint32 aURLCount, nsIXPIProgressDialog *aListener) { return NS_ERROR_NOT_IMPLEMENTED; } /* End of implementation class template. */ #endif #endif /* __gen_nsIXPInstallManager_h__ */